package com.harmontronics.hanma.paas.paas.domain.app.entity.valueobject;

import com.harmontronics.hanma.paas.paas.utils.StringUtil;

/**
 * @Title:
 * @ClassName: RelationTypeEnum
 * @Description:
 * @Author: tylr
 * @Date: 2021/6/1 19:06
 * @Version: 1.0.0
 */
public enum RelationTypeEnum {
    /**
     * 业务模型
     */
    BUSINESS,
    /**
     * 数据字典
     */
    DICTIONARY;

    public final static RelationTypeEnum from(String name){
        if(StringUtil.isNotBlank(name)){
            try {
                return valueOf(name);
            } catch (IllegalArgumentException e) {
                return null;
            }
        }
        return null;
    }

}
